@drawer-width: 60vw;

.mobile {
  .main-menu {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    overflow: auto;
    max-width: 256px;
    z-index: 101;
  }
}

.drawer {
  position: fixed;
  top: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  pointer-events: none;
  > * {
    transition: transform 0.3s cubic-bezier(0.78, 0.14, 0.15, 0.86),
      opacity 0.3s cubic-bezier(0.78, 0.14, 0.15, 0.86),
      box-shaow 0.3s cubic-bezier(0.78, 0.14, 0.15, 0.86),
      -webkit-transform 0.3s cubic-bezier(0.78, 0.14, 0.15, 0.86);
  }
  &-bg,
  &-content-wrapper {
    height: 100%;
    position: absolute;
  }
  &-bg {
    background: #000;
    opacity: 0;
    width: 100%;
    top: 0;
  }
  &-content-wrapper {
    width: @drawer-width;
    left: -@drawer-width;
    background: #fff;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.15);
  }
  &-content {
    overflow: auto;
    height: 100%;
  }
  &-button {
    position: absolute;
    top: 72px;
    width: 41px;
    height: 40px;
    cursor: pointer;
    pointer-events: auto;
    z-index: 0;
    text-align: center;
    line-height: 40px;
    font-size: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #fff;
    box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.15);
    right: -40px;
    border-radius: 0 4px 4px 0;
  }
  &-open {
    pointer-events: auto;
    transform: translateX(@drawer-width);
    transition: transform 0.3s cubic-bezier(0.78, 0.14, 0.15, 0.86) 0s;
    .drawer-bg {
      opacity: 0.3;
    }
  }
  @media (max-width: @mobile-max) {
    .ant-menu-inline .ant-menu-item:after,
    .ant-menu-vertical .ant-menu-item:after {
      left: 0;
      right: auto;
    }
  }
}
